﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Newtonsoft.Json;

namespace poco
{
    public class PhoneNumber : PluralField
    {
        public enum PhoneNumberType {work, home, mobile, fax, pager, other};

        [JsonProperty(PropertyName = "type")]
        public PhoneNumberType Type { get; set; }

        public override bool Equals(object obj)
        {
            if (!base.Equals(obj)) return false;

            if (obj.GetType() != this.GetType()) return false;

            Email other = (Email)obj;

            if (!Object.Equals(this.Type, other.Type)) return false;

            return true;
        }
    }
}
